@nocobase/plugin-field-markdown-vditor 2.1.0-beta.8 → 2.2.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (333) hide show
  1. package/build.config.ts +10 -5
  2. package/client-v2.d.ts +2 -0
  3. package/client-v2.js +1 -0
  4. package/dist/client/715.c6a79599fe53cbbf.js +10 -0
  5. package/dist/client/742.9e3de1a740ca456f.js +10 -0
  6. package/dist/client/index.js +1 -1
  7. package/dist/client-v2/components/Display.d.ts +10 -0
  8. package/dist/client-v2/components/Edit.d.ts +10 -0
  9. package/dist/client-v2/components/const.d.ts +9 -0
  10. package/dist/client-v2/components/index.d.ts +11 -0
  11. package/dist/client-v2/components/style.d.ts +14 -0
  12. package/dist/client-v2/index.d.ts +11 -0
  13. package/dist/client-v2/index.js +10 -0
  14. package/dist/client-v2/interface.d.ts +60 -0
  15. package/dist/client-v2/locale.d.ts +10 -0
  16. package/dist/{client → client-v2}/models/DisplayVditorFieldModel.d.ts +1 -1
  17. package/dist/{client → client-v2}/models/VditorFieldModel.d.ts +1 -1
  18. package/dist/client-v2/models/index.d.ts +10 -0
  19. package/dist/client-v2/plugin.d.ts +20 -0
  20. package/dist/client-v2/runtime.d.ts +21 -0
  21. package/dist/client-v2/vditor/dist/css/content-theme/ant-design.css +210 -0
  22. package/dist/client-v2/vditor/dist/css/content-theme/dark.css +123 -0
  23. package/dist/client-v2/vditor/dist/css/content-theme/light.css +101 -0
  24. package/dist/client-v2/vditor/dist/css/content-theme/wechat.css +94 -0
  25. package/dist/client-v2/vditor/dist/images/emoji/b3log.png +0 -0
  26. package/dist/client-v2/vditor/dist/images/emoji/chainbook.png +0 -0
  27. package/dist/client-v2/vditor/dist/images/emoji/doge.png +0 -0
  28. package/dist/client-v2/vditor/dist/images/emoji/hacpai.png +0 -0
  29. package/dist/client-v2/vditor/dist/images/emoji/huaji.gif +0 -0
  30. package/dist/client-v2/vditor/dist/images/emoji/latke.png +0 -0
  31. package/dist/client-v2/vditor/dist/images/emoji/liandi.png +0 -0
  32. package/dist/client-v2/vditor/dist/images/emoji/lute.png +0 -0
  33. package/dist/client-v2/vditor/dist/images/emoji/octocat.png +0 -0
  34. package/dist/client-v2/vditor/dist/images/emoji/pipe.png +0 -0
  35. package/dist/client-v2/vditor/dist/images/emoji/siyuan.png +0 -0
  36. package/dist/client-v2/vditor/dist/images/emoji/solo.png +0 -0
  37. package/dist/client-v2/vditor/dist/images/emoji/sym.png +0 -0
  38. package/dist/client-v2/vditor/dist/images/emoji/trollface.png +0 -0
  39. package/dist/client-v2/vditor/dist/images/emoji/vditor.png +0 -0
  40. package/dist/client-v2/vditor/dist/images/emoji/wide.png +0 -0
  41. package/dist/client-v2/vditor/dist/images/emoji/wulian.png +0 -0
  42. package/dist/client-v2/vditor/dist/images/img-loading.svg +1 -0
  43. package/dist/client-v2/vditor/dist/images/logo.png +0 -0
  44. package/dist/client-v2/vditor/dist/index.css +1836 -0
  45. package/dist/client-v2/vditor/dist/index.d.ts +76 -0
  46. package/dist/client-v2/vditor/dist/index.min.js +10 -0
  47. package/dist/client-v2/vditor/dist/js/abcjs/abcjs_basic.min.js +12 -0
  48. package/dist/client-v2/vditor/dist/js/echarts/echarts.min.js +32 -0
  49. package/dist/client-v2/vditor/dist/js/flowchart.js/flowchart.min.js +17 -0
  50. package/dist/client-v2/vditor/dist/js/graphviz/full.render.js +99 -0
  51. package/dist/client-v2/vditor/dist/js/graphviz/viz.js +342 -0
  52. package/dist/client-v2/vditor/dist/js/highlight.js/highlight.pack.js +1626 -0
  53. package/dist/client-v2/vditor/dist/js/highlight.js/solidity.min.js +82 -0
  54. package/dist/client-v2/vditor/dist/js/highlight.js/styles/abap.css +155 -0
  55. package/dist/client-v2/vditor/dist/js/highlight.js/styles/algol.css +143 -0
  56. package/dist/client-v2/vditor/dist/js/highlight.js/styles/algol_nu.css +90 -0
  57. package/dist/client-v2/vditor/dist/js/highlight.js/styles/ant-design.css +469 -0
  58. package/dist/client-v2/vditor/dist/js/highlight.js/styles/arduino.css +157 -0
  59. package/dist/client-v2/vditor/dist/js/highlight.js/styles/autumn.css +138 -0
  60. package/dist/client-v2/vditor/dist/js/highlight.js/styles/borland.css +147 -0
  61. package/dist/client-v2/vditor/dist/js/highlight.js/styles/bw.css +150 -0
  62. package/dist/client-v2/vditor/dist/js/highlight.js/styles/colorful.css +158 -0
  63. package/dist/client-v2/vditor/dist/js/highlight.js/styles/dracula.css +140 -0
  64. package/dist/client-v2/vditor/dist/js/highlight.js/styles/emacs.css +167 -0
  65. package/dist/client-v2/vditor/dist/js/highlight.js/styles/friendly.css +183 -0
  66. package/dist/client-v2/vditor/dist/js/highlight.js/styles/fruity.css +123 -0
  67. package/dist/client-v2/vditor/dist/js/highlight.js/styles/github.css +174 -0
  68. package/dist/client-v2/vditor/dist/js/highlight.js/styles/igor.css +124 -0
  69. package/dist/client-v2/vditor/dist/js/highlight.js/styles/lovelace.css +146 -0
  70. package/dist/client-v2/vditor/dist/js/highlight.js/styles/manni.css +139 -0
  71. package/dist/client-v2/vditor/dist/js/highlight.js/styles/monokai.css +132 -0
  72. package/dist/client-v2/vditor/dist/js/highlight.js/styles/monokailight.css +180 -0
  73. package/dist/client-v2/vditor/dist/js/highlight.js/styles/murphy.css +144 -0
  74. package/dist/client-v2/vditor/dist/js/highlight.js/styles/native.css +164 -0
  75. package/dist/client-v2/vditor/dist/js/highlight.js/styles/paraiso-dark.css +137 -0
  76. package/dist/client-v2/vditor/dist/js/highlight.js/styles/paraiso-light.css +136 -0
  77. package/dist/client-v2/vditor/dist/js/highlight.js/styles/pastie.css +180 -0
  78. package/dist/client-v2/vditor/dist/js/highlight.js/styles/perldoc.css +141 -0
  79. package/dist/client-v2/vditor/dist/js/highlight.js/styles/pygments.css +159 -0
  80. package/dist/client-v2/vditor/dist/js/highlight.js/styles/rainbow_dash.css +164 -0
  81. package/dist/client-v2/vditor/dist/js/highlight.js/styles/rrt.css +159 -0
  82. package/dist/client-v2/vditor/dist/js/highlight.js/styles/solarized-dark.css +146 -0
  83. package/dist/client-v2/vditor/dist/js/highlight.js/styles/solarized-dark256.css +146 -0
  84. package/dist/client-v2/vditor/dist/js/highlight.js/styles/solarized-light.css +163 -0
  85. package/dist/client-v2/vditor/dist/js/highlight.js/styles/swapoff.css +144 -0
  86. package/dist/client-v2/vditor/dist/js/highlight.js/styles/tango.css +183 -0
  87. package/dist/client-v2/vditor/dist/js/highlight.js/styles/trac.css +167 -0
  88. package/dist/client-v2/vditor/dist/js/highlight.js/styles/vim.css +144 -0
  89. package/dist/client-v2/vditor/dist/js/highlight.js/styles/vs.css +113 -0
  90. package/dist/client-v2/vditor/dist/js/highlight.js/styles/xcode.css +174 -0
  91. package/dist/client-v2/vditor/dist/js/highlight.js/yul.min.js +39 -0
  92. package/dist/client-v2/vditor/dist/js/i18n/en_US.js +94 -0
  93. package/dist/client-v2/vditor/dist/js/i18n/fr_FR.js +94 -0
  94. package/dist/client-v2/vditor/dist/js/i18n/ja_JP.js +94 -0
  95. package/dist/client-v2/vditor/dist/js/i18n/ko_KR.js +94 -0
  96. package/dist/client-v2/vditor/dist/js/i18n/pt_BR.js +94 -0
  97. package/dist/client-v2/vditor/dist/js/i18n/ru_RU.js +94 -0
  98. package/dist/client-v2/vditor/dist/js/i18n/sv_SE.js +94 -0
  99. package/dist/client-v2/vditor/dist/js/i18n/zh_CN.js +94 -0
  100. package/dist/client-v2/vditor/dist/js/i18n/zh_TW.js +94 -0
  101. package/dist/client-v2/vditor/dist/js/icons/ant.js +183 -0
  102. package/dist/client-v2/vditor/dist/js/icons/material.js +204 -0
  103. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_AMS-Regular.ttf +0 -0
  104. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_AMS-Regular.woff +0 -0
  105. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_AMS-Regular.woff2 +0 -0
  106. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Caligraphic-Bold.ttf +0 -0
  107. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Caligraphic-Bold.woff +0 -0
  108. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Caligraphic-Bold.woff2 +0 -0
  109. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Caligraphic-Regular.ttf +0 -0
  110. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Caligraphic-Regular.woff +0 -0
  111. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Caligraphic-Regular.woff2 +0 -0
  112. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Fraktur-Bold.ttf +0 -0
  113. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Fraktur-Bold.woff +0 -0
  114. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Fraktur-Bold.woff2 +0 -0
  115. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Fraktur-Regular.ttf +0 -0
  116. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Fraktur-Regular.woff +0 -0
  117. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Fraktur-Regular.woff2 +0 -0
  118. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Bold.ttf +0 -0
  119. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Bold.woff +0 -0
  120. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Bold.woff2 +0 -0
  121. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-BoldItalic.ttf +0 -0
  122. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-BoldItalic.woff +0 -0
  123. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-BoldItalic.woff2 +0 -0
  124. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Italic.ttf +0 -0
  125. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Italic.woff +0 -0
  126. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Italic.woff2 +0 -0
  127. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Regular.ttf +0 -0
  128. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Regular.woff +0 -0
  129. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Main-Regular.woff2 +0 -0
  130. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Math-BoldItalic.ttf +0 -0
  131. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Math-BoldItalic.woff +0 -0
  132. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Math-BoldItalic.woff2 +0 -0
  133. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Math-Italic.ttf +0 -0
  134. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Math-Italic.woff +0 -0
  135. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Math-Italic.woff2 +0 -0
  136. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Bold.ttf +0 -0
  137. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Bold.woff +0 -0
  138. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Bold.woff2 +0 -0
  139. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Italic.ttf +0 -0
  140. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Italic.woff +0 -0
  141. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Italic.woff2 +0 -0
  142. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Regular.ttf +0 -0
  143. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Regular.woff +0 -0
  144. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_SansSerif-Regular.woff2 +0 -0
  145. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Script-Regular.ttf +0 -0
  146. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Script-Regular.woff +0 -0
  147. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Script-Regular.woff2 +0 -0
  148. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size1-Regular.ttf +0 -0
  149. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size1-Regular.woff +0 -0
  150. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size1-Regular.woff2 +0 -0
  151. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size2-Regular.ttf +0 -0
  152. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size2-Regular.woff +0 -0
  153. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size2-Regular.woff2 +0 -0
  154. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size3-Regular.ttf +0 -0
  155. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size3-Regular.woff +0 -0
  156. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size3-Regular.woff2 +0 -0
  157. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size4-Regular.ttf +0 -0
  158. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size4-Regular.woff +0 -0
  159. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Size4-Regular.woff2 +0 -0
  160. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Typewriter-Regular.ttf +0 -0
  161. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Typewriter-Regular.woff +0 -0
  162. package/dist/client-v2/vditor/dist/js/katex/fonts/KaTeX_Typewriter-Regular.woff2 +0 -0
  163. package/dist/client-v2/vditor/dist/js/katex/katex.min.css +1 -0
  164. package/dist/client-v2/vditor/dist/js/katex/katex.min.js +10 -0
  165. package/dist/client-v2/vditor/dist/js/katex/mhchem.min.js +10 -0
  166. package/dist/client-v2/vditor/dist/js/lute/lute.min.js +80 -0
  167. package/dist/client-v2/vditor/dist/js/markmap/katex.min.css +1 -0
  168. package/dist/client-v2/vditor/dist/js/markmap/markmap.min.js +8260 -0
  169. package/dist/client-v2/vditor/dist/js/markmap/prism.css +140 -0
  170. package/dist/client-v2/vditor/dist/js/mathjax/LICENSE +202 -0
  171. package/dist/client-v2/vditor/dist/js/mathjax/a11y/assistive-mml.js +10 -0
  172. package/dist/client-v2/vditor/dist/js/mathjax/a11y/complexity.js +10 -0
  173. package/dist/client-v2/vditor/dist/js/mathjax/a11y/explorer.js +10 -0
  174. package/dist/client-v2/vditor/dist/js/mathjax/a11y/semantic-enrich.js +10 -0
  175. package/dist/client-v2/vditor/dist/js/mathjax/input/asciimath.js +10 -0
  176. package/dist/client-v2/vditor/dist/js/mathjax/input/mml/entities.js +10 -0
  177. package/dist/client-v2/vditor/dist/js/mathjax/input/mml.js +10 -0
  178. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/action.js +10 -0
  179. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/all-packages.js +10 -0
  180. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/ams.js +10 -0
  181. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/amscd.js +10 -0
  182. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/autoload.js +10 -0
  183. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/bbox.js +10 -0
  184. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/boldsymbol.js +10 -0
  185. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/braket.js +10 -0
  186. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/bussproofs.js +10 -0
  187. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/cancel.js +10 -0
  188. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/color.js +10 -0
  189. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/colorV2.js +10 -0
  190. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/configMacros.js +10 -0
  191. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/enclose.js +10 -0
  192. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/extpfeil.js +10 -0
  193. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/html.js +10 -0
  194. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/mhchem.js +10 -0
  195. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/newcommand.js +10 -0
  196. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/noerrors.js +10 -0
  197. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/noundefined.js +10 -0
  198. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/physics.js +10 -0
  199. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/require.js +10 -0
  200. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/tagFormat.js +10 -0
  201. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/textmacros.js +10 -0
  202. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/unicode.js +10 -0
  203. package/dist/client-v2/vditor/dist/js/mathjax/input/tex/extensions/verb.js +10 -0
  204. package/dist/client-v2/vditor/dist/js/mathjax/input/tex-base.js +10 -0
  205. package/dist/client-v2/vditor/dist/js/mathjax/input/tex-full.js +10 -0
  206. package/dist/client-v2/vditor/dist/js/mathjax/input/tex.js +10 -0
  207. package/dist/client-v2/vditor/dist/js/mathjax/sre/mathmaps/de.js +113 -0
  208. package/dist/client-v2/vditor/dist/js/mathjax/sre/mathmaps/en.js +119 -0
  209. package/dist/client-v2/vditor/dist/js/mathjax/sre/mathmaps/es.js +113 -0
  210. package/dist/client-v2/vditor/dist/js/mathjax/sre/mathmaps/fr.js +113 -0
  211. package/dist/client-v2/vditor/dist/js/mathjax/sre/mathmaps/mathmaps_ie.js +527 -0
  212. package/dist/client-v2/vditor/dist/js/mathjax/sre/mathmaps/nemeth.js +113 -0
  213. package/dist/client-v2/vditor/dist/js/mathjax/sre/sre-node.js +20 -0
  214. package/dist/client-v2/vditor/dist/js/mathjax/sre/sre_browser.js +1642 -0
  215. package/dist/client-v2/vditor/dist/js/mathjax/tex-svg-full.js +10 -0
  216. package/dist/client-v2/vditor/dist/js/mermaid/mermaid.min.js +1768 -0
  217. package/dist/client-v2/vditor/dist/js/plantuml/plantuml-encoder.min.js +10 -0
  218. package/dist/client-v2/vditor/dist/method.d.ts +50 -0
  219. package/dist/client-v2/vditor/dist/method.min.js +10 -0
  220. package/dist/client-v2/vditor/dist/ts/constants.d.ts +45 -0
  221. package/dist/client-v2/vditor/dist/ts/devtools/index.d.ts +7 -0
  222. package/dist/client-v2/vditor/dist/ts/export/index.d.ts +5 -0
  223. package/dist/client-v2/vditor/dist/ts/hint/index.d.ts +14 -0
  224. package/dist/client-v2/vditor/dist/ts/ir/expandMarker.d.ts +2 -0
  225. package/dist/client-v2/vditor/dist/ts/ir/highlightToolbarIR.d.ts +2 -0
  226. package/dist/client-v2/vditor/dist/ts/ir/index.d.ts +13 -0
  227. package/dist/client-v2/vditor/dist/ts/ir/input.d.ts +2 -0
  228. package/dist/client-v2/vditor/dist/ts/ir/process.d.ts +9 -0
  229. package/dist/client-v2/vditor/dist/ts/ir/processKeydown.d.ts +2 -0
  230. package/dist/client-v2/vditor/dist/ts/markdown/abcRender.d.ts +1 -0
  231. package/dist/client-v2/vditor/dist/ts/markdown/adapterRender.d.ts +37 -0
  232. package/dist/client-v2/vditor/dist/ts/markdown/anchorRender.d.ts +1 -0
  233. package/dist/client-v2/vditor/dist/ts/markdown/chartRender.d.ts +1 -0
  234. package/dist/client-v2/vditor/dist/ts/markdown/codeRender.d.ts +2 -0
  235. package/dist/client-v2/vditor/dist/ts/markdown/flowchartRender.d.ts +1 -0
  236. package/dist/client-v2/vditor/dist/ts/markdown/getHTML.d.ts +2 -0
  237. package/dist/client-v2/vditor/dist/ts/markdown/getMarkdown.d.ts +2 -0
  238. package/dist/client-v2/vditor/dist/ts/markdown/graphvizRender.d.ts +1 -0
  239. package/dist/client-v2/vditor/dist/ts/markdown/highlightRender.d.ts +2 -0
  240. package/dist/client-v2/vditor/dist/ts/markdown/lazyLoadImageRender.d.ts +6 -0
  241. package/dist/client-v2/vditor/dist/ts/markdown/markmapRender.d.ts +1 -0
  242. package/dist/client-v2/vditor/dist/ts/markdown/mathRender.d.ts +10 -0
  243. package/dist/client-v2/vditor/dist/ts/markdown/mediaRender.d.ts +1 -0
  244. package/dist/client-v2/vditor/dist/ts/markdown/mermaidRender.d.ts +1 -0
  245. package/dist/client-v2/vditor/dist/ts/markdown/mindmapRender.d.ts +1 -0
  246. package/dist/client-v2/vditor/dist/ts/markdown/outlineRender.d.ts +2 -0
  247. package/dist/client-v2/vditor/dist/ts/markdown/plantumlRender.d.ts +1 -0
  248. package/dist/client-v2/vditor/dist/ts/markdown/previewRender.d.ts +3 -0
  249. package/dist/client-v2/vditor/dist/ts/markdown/setLute.d.ts +2 -0
  250. package/dist/client-v2/vditor/dist/ts/markdown/speechRender.d.ts +7 -0
  251. package/dist/client-v2/vditor/dist/ts/outline/index.d.ts +7 -0
  252. package/dist/client-v2/vditor/dist/ts/preview/image.d.ts +2 -0
  253. package/dist/client-v2/vditor/dist/ts/preview/index.d.ts +10 -0
  254. package/dist/client-v2/vditor/dist/ts/resize/index.d.ts +6 -0
  255. package/dist/client-v2/vditor/dist/ts/sv/combineFootnote.d.ts +6 -0
  256. package/dist/client-v2/vditor/dist/ts/sv/index.d.ts +13 -0
  257. package/dist/client-v2/vditor/dist/ts/sv/inputEvent.d.ts +2 -0
  258. package/dist/client-v2/vditor/dist/ts/sv/process.d.ts +12 -0
  259. package/dist/client-v2/vditor/dist/ts/sv/processKeydown.d.ts +2 -0
  260. package/dist/client-v2/vditor/dist/ts/tip/index.d.ts +6 -0
  261. package/dist/client-v2/vditor/dist/ts/toolbar/Both.d.ts +5 -0
  262. package/dist/client-v2/vditor/dist/ts/toolbar/Br.d.ts +4 -0
  263. package/dist/client-v2/vditor/dist/ts/toolbar/CodeTheme.d.ts +6 -0
  264. package/dist/client-v2/vditor/dist/ts/toolbar/ContentTheme.d.ts +6 -0
  265. package/dist/client-v2/vditor/dist/ts/toolbar/Counter.d.ts +6 -0
  266. package/dist/client-v2/vditor/dist/ts/toolbar/Custom.d.ts +5 -0
  267. package/dist/client-v2/vditor/dist/ts/toolbar/Devtools.d.ts +5 -0
  268. package/dist/client-v2/vditor/dist/ts/toolbar/Divider.d.ts +4 -0
  269. package/dist/client-v2/vditor/dist/ts/toolbar/EditMode.d.ts +8 -0
  270. package/dist/client-v2/vditor/dist/ts/toolbar/Emoji.d.ts +7 -0
  271. package/dist/client-v2/vditor/dist/ts/toolbar/Export.d.ts +6 -0
  272. package/dist/client-v2/vditor/dist/ts/toolbar/Fullscreen.d.ts +6 -0
  273. package/dist/client-v2/vditor/dist/ts/toolbar/Headings.d.ts +7 -0
  274. package/dist/client-v2/vditor/dist/ts/toolbar/Help.d.ts +5 -0
  275. package/dist/client-v2/vditor/dist/ts/toolbar/Indent.d.ts +5 -0
  276. package/dist/client-v2/vditor/dist/ts/toolbar/Info.d.ts +5 -0
  277. package/dist/client-v2/vditor/dist/ts/toolbar/InsertAfter.d.ts +5 -0
  278. package/dist/client-v2/vditor/dist/ts/toolbar/InsertBefore.d.ts +5 -0
  279. package/dist/client-v2/vditor/dist/ts/toolbar/MenuItem.d.ts +5 -0
  280. package/dist/client-v2/vditor/dist/ts/toolbar/Outdent.d.ts +5 -0
  281. package/dist/client-v2/vditor/dist/ts/toolbar/Outline.d.ts +5 -0
  282. package/dist/client-v2/vditor/dist/ts/toolbar/Preview.d.ts +6 -0
  283. package/dist/client-v2/vditor/dist/ts/toolbar/Record.d.ts +6 -0
  284. package/dist/client-v2/vditor/dist/ts/toolbar/Redo.d.ts +5 -0
  285. package/dist/client-v2/vditor/dist/ts/toolbar/Undo.d.ts +5 -0
  286. package/dist/client-v2/vditor/dist/ts/toolbar/Upload.d.ts +6 -0
  287. package/dist/client-v2/vditor/dist/ts/toolbar/index.d.ts +9 -0
  288. package/dist/client-v2/vditor/dist/ts/toolbar/setToolbar.d.ts +21 -0
  289. package/dist/client-v2/vditor/dist/ts/ui/initUI.d.ts +10 -0
  290. package/dist/client-v2/vditor/dist/ts/ui/setCodeTheme.d.ts +1 -0
  291. package/dist/client-v2/vditor/dist/ts/ui/setContentTheme.d.ts +1 -0
  292. package/dist/client-v2/vditor/dist/ts/ui/setPreviewMode.d.ts +2 -0
  293. package/dist/client-v2/vditor/dist/ts/ui/setTheme.d.ts +2 -0
  294. package/dist/client-v2/vditor/dist/ts/undo/index.d.ts +19 -0
  295. package/dist/client-v2/vditor/dist/ts/upload/getElement.d.ts +2 -0
  296. package/dist/client-v2/vditor/dist/ts/upload/index.d.ts +9 -0
  297. package/dist/client-v2/vditor/dist/ts/upload/setHeaders.d.ts +2 -0
  298. package/dist/client-v2/vditor/dist/ts/util/Options.d.ts +8 -0
  299. package/dist/client-v2/vditor/dist/ts/util/RecordMedia.d.ts +18 -0
  300. package/dist/client-v2/vditor/dist/ts/util/addScript.d.ts +2 -0
  301. package/dist/client-v2/vditor/dist/ts/util/addStyle.d.ts +1 -0
  302. package/dist/client-v2/vditor/dist/ts/util/code160to32.d.ts +1 -0
  303. package/dist/client-v2/vditor/dist/ts/util/compatibility.d.ts +7 -0
  304. package/dist/client-v2/vditor/dist/ts/util/editorCommonEvent.d.ts +10 -0
  305. package/dist/client-v2/vditor/dist/ts/util/fixBrowserBehavior.d.ts +40 -0
  306. package/dist/client-v2/vditor/dist/ts/util/function.d.ts +2 -0
  307. package/dist/client-v2/vditor/dist/ts/util/getSelectText.d.ts +1 -0
  308. package/dist/client-v2/vditor/dist/ts/util/hasClosest.d.ts +9 -0
  309. package/dist/client-v2/vditor/dist/ts/util/hasClosestByHeadings.d.ts +2 -0
  310. package/dist/client-v2/vditor/dist/ts/util/highlightToolbar.d.ts +2 -0
  311. package/dist/client-v2/vditor/dist/ts/util/hotKey.d.ts +1 -0
  312. package/dist/client-v2/vditor/dist/ts/util/log.d.ts +1 -0
  313. package/dist/client-v2/vditor/dist/ts/util/merge.d.ts +1 -0
  314. package/dist/client-v2/vditor/dist/ts/util/processCode.d.ts +3 -0
  315. package/dist/client-v2/vditor/dist/ts/util/selection.d.ts +15 -0
  316. package/dist/client-v2/vditor/dist/ts/util/toc.d.ts +6 -0
  317. package/dist/client-v2/vditor/dist/ts/wysiwyg/afterRenderEvent.d.ts +6 -0
  318. package/dist/client-v2/vditor/dist/ts/wysiwyg/highlightToolbarWYSIWYG.d.ts +5 -0
  319. package/dist/client-v2/vditor/dist/ts/wysiwyg/index.d.ts +22 -0
  320. package/dist/client-v2/vditor/dist/ts/wysiwyg/inlineTag.d.ts +11 -0
  321. package/dist/client-v2/vditor/dist/ts/wysiwyg/input.d.ts +2 -0
  322. package/dist/client-v2/vditor/dist/ts/wysiwyg/processKeydown.d.ts +3 -0
  323. package/dist/client-v2/vditor/dist/ts/wysiwyg/renderDomByMd.d.ts +6 -0
  324. package/dist/client-v2/vditor/dist/ts/wysiwyg/setHeading.d.ts +3 -0
  325. package/dist/client-v2/vditor/dist/ts/wysiwyg/showCode.d.ts +2 -0
  326. package/dist/client-v2/vditor/dist/ts/wysiwyg/toolbarEvent.d.ts +2 -0
  327. package/dist/client-v2/vditor/dist/types/index.d.ts +866 -0
  328. package/dist/externalVersion.js +8 -6
  329. package/dist/node_modules/fs-extra/lib/index.js +1 -1
  330. package/dist/node_modules/fs-extra/package.json +1 -1
  331. package/package.json +3 -2
  332. package/dist/client/478dab5e65264134.js +0 -10
  333. package/dist/client/b6153ca4835aefdd.js +0 -10
package/build.config.ts CHANGED
@@ -3,13 +3,18 @@ import fs from 'fs/promises';
3
3
  import path from 'path';
4
4
 
5
5
  const vditor = path.dirname(require.resolve('vditor'));
6
+ const vditorTargets = ['dist/client/vditor/dist', 'dist/client-v2/vditor/dist'];
6
7
 
7
8
  export default defineConfig({
8
9
  afterBuild: async (log) => {
9
- log('coping vditor dist');
10
- await fs.cp(vditor, path.resolve(__dirname, 'dist/client/vditor/dist'), {
11
- recursive: true,
12
- force: true,
13
- });
10
+ log('copying vditor dist');
11
+ await Promise.all(
12
+ vditorTargets.map((target) =>
13
+ fs.cp(vditor, path.resolve(__dirname, target), {
14
+ recursive: true,
15
+ force: true,
16
+ }),
17
+ ),
18
+ );
14
19
  },
15
20
  });
package/client-v2.d.ts ADDED
@@ -0,0 +1,2 @@
1
+ export * from './dist/client-v2';
2
+ export { default } from './dist/client-v2';
package/client-v2.js ADDED
@@ -0,0 +1 @@
1
+ module.exports = require('./dist/client-v2/index.js');
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file is part of the NocoBase (R) project.
3
+ * Copyright (c) 2020-2024 NocoBase Co., Ltd.
4
+ * Authors: NocoBase Team.
5
+ *
6
+ * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License.
7
+ * For more information, please refer to: https://www.nocobase.com/agreement.
8
+ */
9
+
10
+ "use strict";(self.webpackChunk_nocobase_plugin_field_markdown_vditor=self.webpackChunk_nocobase_plugin_field_markdown_vditor||[]).push([["715"],{590:function(e,t,r){r.r(t),r.d(t,{default:function(){return O},MarkdownVditor:function(){return _}});var n=r(230),o=r(342),i=r(59),l=r(155),a=r.n(l),u=r(597),c=r.n(u),d=r(502),s=function(){var e=(0,o.usePlugin)(d.PluginFieldMarkdownVditorClient);return e.dependencyLoaded||(e.initVditorDependency(),e.dependencyLoaded=!0),e.getCDN()},f=(0,o.genStyleHook)("nb-field-markdown-vditor",function(e){var t,r,n;return t={},r=e.componentCls,n={position:"relative",overflow:"visible","&:hover, &:focus-within":{zIndex:1e3},".vditor-reset":{fontSize:"".concat(e.fontSize,"px !important"),color:"unset",padding:"10px !important"},".vditor":{borderRadius:8,overflow:"visible"},".vditor .vditor-content":{borderRadius:"0 0 8px 8px",overflow:"hidden"},".vditor .vditor-toolbar":{position:"relative",overflow:"visible",paddingLeft:" 16px !important",borderRadius:"8px 8px 0 0"},".vditor .vditor-tooltipped:hover, .vditor .vditor-tooltipped:focus, .vditor .vditor-tooltipped:active":{zIndex:1e3},".vditor .vditor-toolbar .vditor-tooltipped__n::after, .vditor .vditor-toolbar .vditor-tooltipped__ne::after, .vditor .vditor-toolbar .vditor-tooltipped__nw::after":{top:"100%",bottom:"auto",marginTop:5,marginBottom:0},".vditor .vditor-toolbar .vditor-tooltipped__n::before, .vditor .vditor-toolbar .vditor-tooltipped__ne::before, .vditor .vditor-toolbar .vditor-tooltipped__nw::before":{top:"auto",bottom:-5,borderTopColor:"transparent",borderBottomColor:"#3b3e43"},".vditor .vditor-content .vditor-ir .vditor-reset":{paddingLeft:" 16px !important"},".vditor-ir pre.vditor-reset":{backgroundColor:"".concat(e.colorBgContainer,"!important")}},r in t?Object.defineProperty(t,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[r]=n,t});function v(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function p(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,o=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=o){var i=[],l=!0,a=!1;try{for(o=o.call(e);!(l=(r=o.next()).done)&&(i.push(r.value),!t||i.length!==t);l=!0);}catch(e){a=!0,n=e}finally{try{l||null==o.return||o.return()}finally{if(a)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return v(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return v(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var m=function(e){if(e){var t=document.createRange();return t.selectNodeContents(e),t.getBoundingClientRect().width}};function b(e){var t,r=(0,l.useRef)(null),n=f(),o=n.wrapSSR,i=n.componentCls,u=n.hashId,d=s();return(0,l.useEffect)(function(){var t;c().preview(r.current,null!=(t=e.value)?t:"",{mode:"light",cdn:d}),setTimeout(function(){var e;null==(e=r.current)||e.querySelectorAll("img").forEach(function(e){e.style.cursor="zoom-in",e.addEventListener("click",function(){var t=e.src;if(!document.getElementById("custom-image-preview")){var r=document.createElement("span");r.id="custom-image-preview",Object.assign(r.style,{position:"fixed",inset:"0",backgroundColor:"rgba(0,0,0,0.85)",display:"flex",alignItems:"center",justifyContent:"center",zIndex:"9999",cursor:"zoom-out"});var n=document.createElement("img");n.src=t,Object.assign(n.style,{maxWidth:"90%",maxHeight:"90%",borderRadius:"8px",boxShadow:"0 0 20px rgba(0,0,0,0.5)",transition:"transform 0.2s",cursor:"zoom-out"}),r.addEventListener("click",function(){document.body.removeChild(r)}),r.appendChild(n),document.body.appendChild(r)}})})},0)},[e.value]),o(a().createElement("span",{className:"".concat(u," ").concat(i)},a().createElement("span",{ref:r,style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({border:"none"},null!=(t=null==e?void 0:e.style)?t:{})})))}var y=(0,o.withDynamicSchemaProps)(function(e){var t,r=(0,n.useField)(),o=null!=(t=e.value)?t:null==r?void 0:r.value,u=s(),d=(0,l.useRef)(),f=p((0,l.useState)(!1),2),v=f[0],y=f[1],h=p((0,l.useState)(!1),2),g=h[0],w=h[1],S=p((0,l.useState)(""),2),x=S[0],C=S[1],E=(0,l.useRef)();(0,l.useEffect)(function(){if(e.value&&(!r||(null==r?void 0:r.value)))if(e.ellipsis)c().md2html(e.value,{mode:"light",cdn:u}).then(function(e){var t,r;C(((t=document.createElement("div")).innerHTML=e,r=t.innerText,t=null,(null==r?void 0:r.replace(/[\n\r]/g,""))||""))}).catch(function(){return C("")});else{var t;c().preview(d.current,null!=(t=e.value)?t:null==r?void 0:r.value,{mode:"light",cdn:u})}},[e.value,e.ellipsis,null==r?void 0:r.value]);var _=(0,l.useCallback)(function(){var e;return!!E.current&&m(E.current)>(null==(e=E.current)?void 0:e.offsetWidth)},[E]);return e.ellipsis?a().createElement(i.Popover,{open:v,onOpenChange:function(e){y(g&&e)},content:a().createElement(b,{value:o,style:{maxWidth:500,maxHeight:400,overflowY:"auto"}})},a().createElement("div",{ref:E,style:{overflow:"hidden",overflowWrap:"break-word",textOverflow:"ellipsis",whiteSpace:"nowrap",wordBreak:"break-all"},onMouseEnter:function(e){var t=e.target;_()&&w(t.scrollWidth>=t.clientWidth)}},x)):a().createElement(b,{value:o})}),h=r(953),g=r(280),w=r(872);function S(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function x(e,t,r,n,o,i,l){try{var a=e[i](l),u=a.value}catch(e){r(e);return}a.done?t(u):Promise.resolve(u).then(n,o)}var C=["en_US","fr_FR","pt_BR","ja_JP","ko_KR","ru_RU","sv_SE","zh_CN","zh_TW"],E=(0,o.withDynamicSchemaProps)(function(e){var t,r=e.disabled,n=e.onChange,i=e.value,u=e.fileCollection,d=e.toolbar,v=e.editMode,p=void 0===v?"ir":v,m=function(e){if(Array.isArray(e))return e}(t=(0,l.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var o=[],i=!0,l=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(o.push(t.value),2!==o.length);i=!0);}catch(e){l=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(l)throw r}}return o}}(t)||function(e){if(e){if("string"==typeof e)return S(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return S(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),b=m[0],y=m[1],E=(0,l.useRef)(),_=(0,l.useRef)(!1),O=(0,l.useRef)(null),R=(0,l.useRef)(null),k=(0,o.useAPIClient)(),I=s(),j=f(),A=j.wrapSSR,P=j.hashId,T=j.componentCls,L=k.auth.locale||"en-US",z=(0,o.usePlugin)("@nocobase/plugin-file-manager"),M=(0,o.useCompile)(),N=(0,l.useRef)(M);N.current=M;var F=(0,h.useTranslation)().t,V=(0,o.useZIndexContext)(),W=(0,o.getZIndex)("drawer",V+1e3,0),q=(0,l.useMemo)(function(){var e=L.replace(/-/g,"_");return C.includes(e)?e:"en_US"},[L]);return(0,l.useEffect)(function(){if(O.current){var e=null!=d?d:g.r,t=new(c())(O.current,{value:null!=i?i:"",lang:q,cache:{enable:!1},undoDelay:0,preview:{math:{engine:"KaTeX"}},toolbar:e,fullscreen:{index:1200},cdn:I,minHeight:200,mode:p,after:function(){E.current=t,y(!0);var e=window.scrollX||window.pageXOffset,n=window.scrollY||window.pageYOffset;t.setValue(null!=i?i:""),requestAnimationFrame(function(){window.scrollTo(e,n)}),r?t.disabled():t.enable()},input:function(e){n(e)},upload:{multiple:!1,fieldName:"file",handler:function(e){var r;return(r=function(){var r,n,o,i,l,a,c,d,s,f,v,p,m,b,y;return function(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},l=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),a=Object.defineProperty;return a(l,"next",{value:u(0)}),a(l,"throw",{value:u(1)}),a(l,"return",{value:u(2)}),"function"==typeof Symbol&&a(l,Symbol.iterator,{value:function(){return this}}),l;function u(a){return function(u){var c=[a,u];if(r)throw TypeError("Generator is already executing.");for(;l&&(l=0,c[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&c[0]?n.return:c[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,c[1])).done)return o;switch(n=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,n=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===c[0]||2===c[0])){i=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){i.label=c[1];break}if(6===c[0]&&i.label<o[1]){i.label=o[1],o=c;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(c);break}o[2]&&i.ops.pop(),i.trys.pop();continue}c=t.call(e,i)}catch(e){c=[6,e],n=0}finally{r=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}(this,function(h){switch(h.label){case 0:return d=e[0],t.focus(),[4,k.resource("vditor").check({fileCollectionName:u})];case 1:if(!(null==(s=h.sent().data)||null==(r=s.data)?void 0:r.isSupportToUploadFiles))return t.tip(F("vditor.uploadError.message",{ns:w.C,storageTitle:null==(f=s.data.storage)?void 0:f.title}),0),[2];return t.tip(F("uploading"),0),[4,z.uploadFile({file:d,fileCollectionName:u,storageId:null==s||null==(o=s.data)||null==(n=o.storage)?void 0:n.id,storageType:null==s||null==(l=s.data)||null==(i=l.storage)?void 0:i.type,storageRules:null==s||null==(c=s.data)||null==(a=c.storage)?void 0:a.rules})];case 2:if(p=(v=h.sent()).data,m=v.errorMessage)return t.tip(N.current(m),3e3),[2];if(!p)return t.tip(F("Response data is empty",{ns:w.C}),3e3),[2];return b=p.filename,y=p.url,d.type.startsWith("image/")?t.insertValue("![".concat(b,"](").concat(y,")")):t.insertValue("[".concat(b,"](").concat(y,")")),t.tip(F(""),10),[2,null]}})},function(){var e=this,t=arguments;return new Promise(function(n,o){var i=r.apply(e,t);function l(e){x(i,n,o,l,a,"next",e)}function a(e){x(i,n,o,l,a,"throw",e)}l(void 0)})})()}}}),o=O.current;if(o){var l=new MutationObserver(function(){var e=o.classList.contains("vditor--fullscreen"),t=o.querySelectorAll(".vditor-reset"),r=o.querySelectorAll(".vditor-toolbar");t.forEach(function(t){t.style.padding=e?"10px 200px":""}),r.forEach(function(t){t.style.paddingLeft=e?"200px":""})});return l.observe(o,{attributes:!0,attributeFilter:["class"]}),function(){var e;null==(e=E.current)||e.destroy(),E.current=void 0,l.disconnect()}}}},[null==d?void 0:d.join(","),p]),(0,l.useEffect)(function(){if(b&&E.current){var e=E.current;if(i!==e.getValue()){var t,r,n,o,l=window.scrollX||window.pageXOffset,a=window.scrollY||window.pageYOffset;e.setValue(null!=i?i:"");var u=null==(t=O.current)?void 0:t.querySelector("div.vditor-content > div.vditor-ir > pre"),c=null==(r=O.current)?void 0:r.querySelector(".vditor-content"),d=u&&(document.activeElement===u||u.contains(document.activeElement)||(null==(o=document.activeElement)||null==(n=o.closest)?void 0:n.call(o,".vditor-content"))===c);if(u&&d){var s=document.createRange(),f=window.getSelection();f&&(s.selectNodeContents(u),s.collapse(!1),f.removeAllRanges(),f.addRange(s))}d||requestAnimationFrame(function(){window.scrollTo(l,a)})}}},[i,b]),(0,l.useEffect)(function(){b&&E.current&&(r?E.current.disabled():E.current.enable())},[r,b]),(0,l.useEffect)(function(){if(R.current){var e=new MutationObserver(function(e){var t=!0,r=!1,n=void 0;try{for(var o,i=e[Symbol.iterator]();!(t=(o=i.next()).done);t=!0){var l=o.value,a=!0,u=!1,c=void 0;try{for(var d,s=Array.from(l.addedNodes)[Symbol.iterator]();!(a=(d=s.next()).done);a=!0){var f,v=d.value;f=HTMLElement,(null!=f&&"u">typeof Symbol&&f[Symbol.hasInstance]?!!f[Symbol.hasInstance](v):v instanceof f)&&v.classList.contains("vditor-img")&&(R.current.appendChild(v),v.style.zIndex=String(W))}}catch(e){u=!0,c=e}finally{try{a||null==s.return||s.return()}finally{if(u)throw c}}}}catch(e){r=!0,n=e}finally{try{t||null==i.return||i.return()}finally{if(r)throw n}}});return e.observe(document.body,{childList:!0}),function(){e.disconnect()}}},[W]),(0,l.useLayoutEffect)(function(){if(O.current){var e=new ResizeObserver(function(e){var t=!0,r=!1,n=void 0;try{for(var o,i=e[Symbol.iterator]();!(t=(o=i.next()).done);t=!0){var l,a=o.value.target;a.className.includes("vditor--fullscreen")?(document.body.appendChild(a),_.current=!0):_.current&&(null==(l=R.current)||l.appendChild(a),_.current=!1)}}catch(e){r=!0,n=e}finally{try{t||null==i.return||i.return()}finally{if(r)throw n}}});return e.observe(O.current),function(){e.unobserve(O.current)}}},[]),A(a().createElement("div",{ref:R,className:"".concat(P," ").concat(T)},a().createElement("div",{ref:O})))}),_=(0,o.withDynamicSchemaProps)((0,n.connect)(E,(0,n.mapReadPretty)(y))),O=_}}]);